package lion.framework.core.web.exception;

/**
 * 自定义Exception ,返回时将带有状态码
 * 
 * @author lion
 * @email hl_0074@sina.com
 * @date 2015年3月18日
 */
public class WebException extends RuntimeException {

	private static final long serialVersionUID = 1189703911387531336L;

	private int status = 500;

	public WebException(int status) {

		this.status = status;
	}

	public WebException(String message) {

		super(message);
	}

	public WebException(int status, String message) {

		super(message);
		this.status = status;
	}

	public WebException(int status, String message, Throwable throwable) {

		super(message, throwable);
		this.status = status;
	}

	public WebException(String message, Throwable throwable) {

		super(message, throwable);
	}

	public WebException(int status, Throwable throwable) {

		super(throwable);
		this.status = status;
	}

	public int getStatus() {

		return status;
	}
}
